import axios from "./axios";

export const getlogin = (data: Object) => {
    return axios({
        url: 'http://localhost:9000/api/login',
        method: 'post',
        data
    })
}
//仓库天气
export const getweather = () => {
    return axios({
        url: 'http://v1.yiketianqi.com/api',
        method: 'get',
        params: {
            unescape: 1,
            version: "v63",
            appid: '92328197',
            appsecret: "i6QQn6Z4"
        }
    })
}
//天气1
// export const getweather1 = () => {
//     return axios({
//         url: 'http://v1.yiketianqi.com/free/month',
//         method: 'get',
//         params: {
//             unescape: 1,
//             appid: "92328197",
//             appsecret: 'i6QQn6Z4'
//         }
//     })
// }
//学生分布情况
export const getstudent = () => {
    return axios({
        url: '/v1.0/api/intelligentDetection/data',
        method: 'get'
    })
}
//水电用量
export const getwater = () => {
    return axios({
        url: "/v1.0/api/intelligentDetection/dataTop",
        method: "get"
    })
}
//外来访客
export const getxiao = () => {
    return axios({
        url: "/v1.0/api/intelligentDetection/dataBottom",
        method: "get"
    })
}
//场地使用
export const getchang = () => {
    return axios({
        url: "/v1.0/api/deviceWorking/venueUse",
        method: "get"
    })
}

//two
export const getcity = () => {
    return axios({
        url: "/v1.0/api/student/stats/byAreaCode",
        method: 'get'
    })
}
//地图
export const getmap = (adcode: number) => {
    return axios({
        url: `https://geo.datav.aliyun.com/areas_v3/bound/geojson?code=${adcode}_full`,
        method: 'get'
    })
}
//薪资
export const getmoney = () => {
    return axios({
        url: "/v1.0/api/student/stats/salary",
        method: 'get'
    })
}
//状态
export const getstatus = () => {
    return axios({
        url: '/v1.0/api/student/stats/status',
        method: 'get'
    })
}
//监控
export const getjiank = () => {
    return axios({
        url: '/v1.0/api/safeManage/monitoringSituation',
        method: "get"
    })
}
//流向城市
export const getcheng = () => {
    return axios({
        url: "/v1.0/api/student/stats/distribution",
        method: 'get'
    })
}
//门禁情况
export const getmenjin = () => {
    return axios({
        url: "/v1.0/api/safeManage/dutySituation",
        method: 'get'
    })
}
//值班情况
export const getzhi = () => {
    return axios({
        url: '/v1.0/api/safeManage/entranceGuardSituation',
        method: 'get'
    })
}
//监控画面
export const gethua = () => {
    return axios({
        url: '/v1.0/api/safeManage/monitoringList',
        method: "get"
    })
}
//设备统计
export const getshebei = () => {
    return axios({
        url: '/v1.0/api/deviceWorking/equipment',
        method: 'get'
    })
}
//实时用电
export const getdian = () => {
    return axios({
        url: '/v1.0/api/deviceWorking/electricityConsumption',
        method: 'get'
    })
}
//场地使用
export const getchangdi = () => {
    return axios({
        url: '/v1.0/api/deviceWorking/venueUse',
        method: 'get'
    })
}
//设备名称
export const getshe = () => {
    return axios({
        url: '/v1.0/api/deviceWorking/equipmentTesting',
        method: "get"
    })
}
//警报
export const getjing = () => {
    return axios({
        url: "/v1.0/api/deviceWorking/allPoliceData",
        method: 'get'
    })
}